#pragma once

#ifndef SCENEMANAGER_H
#define SCENEMANAGER_H

#endif // SCENEMANAGER_H

#include <vector>
#include<QObject>
#include<QDebug>
#include "MenyScene.h"

class SceneManager: public QObject
{
 Q_OBJECT
public:
    SceneManager(QRect &r);
    ~SceneManager();

    MenyScene* GetScene(int number);
    MenyScene* GetCurrentScene();
    void ConnectMenis();
private slots:
    void slotSetMainMeny();
    void slotSetServerMeny();
    void slotSetClientMeny();
    void slotSetGame();
    //void slotSetClientGame();
    void slotPresEscKey();
    void slotPresKey(QKeyEvent * event);
    void slotConnectToTheServer();
public slots:
    void slotExitButton();

signals:
    void signalChanged(MenyScene*);
    void signalGameStart();
    void signalClientGameConnect(QString, QString,QString);
    void signalEnd();
    void signalPresEscKey();
    void signalPresKey(QKeyEvent * event);
    void signalCreateServer(QString);

private:
    std::vector<MenyScene* > GameScens;
    int items;
    int activ;
};
